// 数据状态
const state = {
    userData: [],
    MenuData: [],
};
// 同步更新状态方法
const mutations = {
    CHANGE_USERDATA(state, payload) {
        state.userData = payload;
    },
    CHANGE_MENUDATA(state, payload) {
        state.MenuData = payload;
    },
};
const store = {
    // namespaced 开启命名空间,作用是为了方式不同的模块命名冲突;
    namespaced: true,
    state,
    mutations,
};
export default store;